home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Experimental BBS Explossion 3
/
Experimental BBS Explossion III.iso
/
others
/
graf_m.zip
/
GRAF.DOC
< prev
next >
Wrap
Text File
|
1993-08-20
|
5KB
|
153 lines
/*
/////////////////////////////////////////////////////////////////////////////
/ /
/ Graf, v1.0 /
/ /
/ /
/ Written by Jason Smart /
/ Travelling Faire Software /
/ /
/////////////////////////////////////////////////////////////////////////////
ABOUT
Graf graphs functions of one or two independent variables.
It can graph in a variety of graphics modes, using
different line and fill colors, and different resolutions.
Graphs may also be easily rotated/resized/moved.
ENTERING EQUATIONS
Graf accepts both capitalized and uncapitalized letters
in equations.
Acceptable Variables include the following:
X The x distance of the given point from the origin
Y The y...
R The radial distance from the origin, R = sqrt(sqr(x) + sqr(y))
Acceptable functions include the following:
ABS absolute value
SQR square
SQRT square root
COS cosine
SIN sine
TAN tangent
ACOS arc-cosine
ASIN arc-sine
ATAN arc-tangent
EXP exponential, eg: e^x
LN natural(base e) log
LOG base 10 log
INT integer part of argument, eg: int(10.23) = 10
FRAC fractional part of argument, eg: frac(10.23) = 0.23
COSH hyperbolic cosine
SINH hyperbolic sine
TANH hyperbolic tangent
Acceptable operations:
+ add, eg: 5+x 3+2 r+tanh(5) etc
- subtract
* multiply
/ divide
^ raise to the power of, eg: y^2 is the same as sqr(y)
In Graf, three dimensional graphs use functions of the
form z = F(x,y,r), such as:
z = sin(r) z = x^3 + y^4 z = abs(y * r)
Two dimensional graphs use functions of the form z = F(x),
such as:
z = sin(x) z = x^3 - 5 z = abs(x) etc
Any y variable appearing in a two dimensional equation
is set to zero, so for example z=y would be interpreted
as z=0 when graphing in two dimensions. Also, since R
is defined as sqrt( sqr(x) + sqr(y) ), when graphing in
two dimensions it will reduce to sqrt( sqr(x) ), since
y is zero. Therefore, r = abs(x) in two dimensional
graphs, which makes sense since r is the (positive) radial
distance from the origin.
GRAPHING EQUATIONS
Press '?' anytime while graphing for graph help.
Anytime while graphing, press:
4,6 Rotate 3D object around body z axis.
2,8 Rotate 3D object around fixed x axis
1,7 or around fixed z axis.
h Draw in High Resolution - very slow, but worth it.
imjl Move entire object up/down/left/right.
CTRL-imjl Move entire object up/down/left/right faster.
*,/ Change z scale.
+,- Change x & y scale. In 2D changes x scale only.
g Change graphics mode: Lines Only, Fill Only, or Lines & Fill.
z Call SETUP.
a Toggle drawing axis.
b Toggle drawing border around object. Not used for radial graphs
d Toggle drawing graph itself.
s Toggle drawing equation string and labelling axis.
c Change fill color.
p Change line color.
q,ESC Quit to main menu.
More on changing graphics mode:
The three modes in three and two dimensions are:
3D: Line Only: Draws only the lines connecting each z=F(x,y) point.
Fill Only: Fills between the z=F(x,y), where the brightness
of the fill color represents the general height of
the graph at those points.
Line & Fill: Does both.
2D: Point Only: Draws only individual points, representing z=F(x).
Line Only: Draws lines between the individual points.
Point & Line:Does both.
OTHER NOTES
Note that radial graphs are useful only at higher
resolutions - at lower resolutions the graphs will
appear choppy, broken.
Sometimes, when switching between 2D and 3D graphs,
or when changing the equation, the graph will appear
extremely compacted or expanded. This is due to an
extremely large/small XY or Z scale. When these
problems occur, repeatedly pressing '/' or '*'
(reduce/expand Z scale) or '-+' (reduce/expand XY
scale) should fix the problem.
QUESTION/COMMENTS:
EMail: Jules33 America Online
Jules33@aol.com Internet
or write: Jason Smart
1158 Panoramic Dr.
Martinez, CA 94553
This program may be distributed freely, as long as this
documentation file remains with it.